#include "stdio.h"

int main() {
	int a;
	int n;
	int t;
	int i = 1;
	int sum = 0;
	scanf("%d%d", &n, &a);
	t = a;
	while (i <= n) {
		printf("%d\n", t);
		t = t * 10 + a;
		sum = sum + t;
		i++;
	}
	printf("sum=%d", sum);
}